package com.xcity.game.activity2.share;

import com.xcity.game.account.AccountChannel;
import com.xcity.game.activity2.share.action.QQShareAction;
import com.xcity.game.activity2.share.action.WeiboShareAction;
import com.xcity.util.BackDoorHandler;

public class ShareActionFactory {
	
	static ShareAction qqAction = new QQShareAction();
	static ShareAction weiboAction = new WeiboShareAction();
	
	private ShareActionFactory() {
	}
	
	public static ShareAction create(AccountChannel channel) {
		if (channel == AccountChannel.SINA) {
			return weiboAction;
		}
		if (channel == AccountChannel.QQ_WANBA || channel == AccountChannel.QQ) {
			return qqAction;
		}
		if (BackDoorHandler.CHEAT_ENABLE) {
			return qqAction;
		}
		return null;
	}
}
